using System.Web.Mvc;
using System.Web.Routing;

using Azure.Web.Controllers;

namespace Azure.Web.Configuration
{
    public static class Routing
    {
        public static void Configure(RouteCollection routes)
        {
            routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
            routes.IgnoreRoute("{resource}.ico");

            routes.MapRoute("Home", "", new { controller = Blog.Controller, action = Blog.Index, id = string.Empty });
            routes.MapRoute("DateSlug", "{year}/{month}/{day}/{slug}/{action}", new { controller = Blog.Controller, action = Blog.View });
            
            routes.MapRoute("Controllers", "{controller}/{action}/{id}", new { controller = Blog.Controller, action = Blog.Index, id = string.Empty });
        }
    }
}